if __name__ == "__main__":
    """
    create crontab trigger
    """
    """
    crontab_args = dict()
    crontab_args['year']        = None
    crontab_args['month']       = None
    crontab_args['day']         = None
    crontab_args['week']        = None
    crontab_args['day_of_week'] = None
    crontab_args['hour']        = None
    crontab_args['minute']      = 5
    crontab_args['second']      = None
    crontab_args['start_date']  = None
    crontab_args['end_date']    = None
    crontab_args['timezone']    = None
    print time.localtime()
    cron_trigger = APSchedTriggerFactory.create_trigger_instance('crontab', crontab_args)
    print time.localtime()
    """
    """
    create interval trigger
    """
    interval_args = dict()
    interval_args['weeks']   = 0
    interval_args['days']    = 0
    interval_args['hours']   = 0
    interval_args['minutes'] = 0
    interval_args['seconds'] = 5
    interval_args['start_date'] = None
    interval_args['end_date']   = None
    interval_args['timezone']   = None
    print time.localtime()
    interval_trigger = APSchedTriggerFactory.create_trigger_instance('interval', interval_args)
    print time.localtime()

    """
    create date trigger
    """
    date_args = dict()
    date_args['run_date'] = '2015-03-09 20:00:00'
    date_args['timezone'] = None
    print (time.localtime())
    date_trigger = APSchedTriggerFactory.create_trigger_instance('datetime', date_args)
    print (time.localtime())
